<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<div th:include="~{common/top}"></div>
<head>
<link rel="stylesheet" href="css/shop.css">
<style >
    @font-face {
        font-family: 'cm';
        src: url("font/Begilas.otf");
    }

    #BackLink{
        top: 20px;
    }

</style>
</head>
<body>
<div class="display">

    <div id="Catalog">

        <div class="PetPicAndName" th:utext="${session.product.getDescription()} + ' ' +${session.product.getName()}"></div>

        <table>
            <tr>
                <th>Product ID</th>
                <th>Description</th>
                <th>List Price</th>
                <th style="border: none">&nbsp;</th>
            </tr>

            <tr th:each="item:${session.itemList}">
                    <td th:text="${item.itemId}"></td>
                    <td th:text="${item.attribute1}"></td>
                    <td th:text="${item.getListPrice()}"><fmt:formatNumber  pattern="$#,##0.00"/></td>
                    <td style="border: none">
                        <a th:href="@{/addItemToCart(workingItemId=${item.getItemId()})}"><button id="buyButton"></button></a>
                    </td>
            </tr>

        </table>

    </div>

    <div id="BackLink">
        <a href="mainForm">
            <button><span>返回主页面</span></button>
        </a>
    </div>

</div>
</body>
</html>